<?php 
//echo $_SERVER['REMOTE_ADDR'];
$ip = '192.168.4.179';
//echo ip2long($ip);
echo sprintf('%u',ip2long($ip));